package cn.com.mrzheng.web.utils;

import org.springframework.beans.factory.annotation.Value;

/**
 * 微服务REST API. 此处定义的URL可用于服务对外提供的地址及HTTP客户端请求地址.
 * URL定义遵循健康档案平台REST规范.
 *
 * @author Sand
 * @version 1.0
 * @created 2015.09.09 15:04
 */
public class ServiceApi {

    @Value("${service-gateway.CrossOrigin}")
    private static String crossOrigin;

    public static class Config {
       public static final String CrossOrigin = "http://localhost:8888";
    }

    public static class Login {
        public static final String LOGIN = "/api/login/login";
        public static final String RIGISTER = "/api/login/register";
        public static final String  FOGETPASSWORD = "/api/login/restpassword";
        public static final String  DELETE = "/api/login/delete";
    }

    public static class Post {
        public static final String ADD = "/api/post/add";
        public static final String DELETE = "/api/post/delete";
        public static final String  LIST = "/api/post/list";
        public static final String  UPDATE = "/api/post/update";
    }

    public static class QiNiu {
        public static final String Token = "/api/qiniu/getToken";
    }

    public static class Role {
        public static final String SAVE = "/api/role/save";
        public static final String DELETE = "/api/role/delete";
        public static final String  LIST = "/api/role/list";
        public static final String  GET = "/api/role/get";
    }

    public static class Auth {
        public static final String SAVE = "/api/auth/save";
        public static final String DELETE = "/api/auth/delete";
        public static final String  LIST = "/api/auth/list";
        public static final String  GET = "/api/auth/get";
    }

    public static class User {
        public static final String SAVE = "/api/user/save";
        public static final String DELETE = "/api/user/delete";
        public static final String  LIST = "/api/user/list";
        public static final String  GET = "/api/user/get";
    }

    public static class UserRole {
        public static final String SAVE = "/api/userrole/save";
        public static final String DELETE = "/api/userrole/delete";
        public static final String  LIST = "/api/userrole/list";
        public static final String  GET = "/api/userrole/get";
    }

    public static class RoleAuth {
        public static final String SAVE = "/api/roleauth/save";
        public static final String DELETE = "/api/roleauth/delete";
        public static final String  LIST = "/api/roleauth/list";
        public static final String  GET = "/api/roleauth/get";
    }
}
